//
//  WCAddrEditCell.m
//  CBT
//
//  Created by apple on 2019/7/9.
//  Copyright © 2019 Mr.Zhang. All rights reserved.
//

#import "WCAddrEditCell.h"

@implementation WCAddrEditCell

+ (instancetype)createTableView:(UITableView *)tableView {
    WCAddrEditCell *cell = [tableView dequeueReusableCellWithIdentifier:@"addreditCell"];
    cell.selectionStyle  = UITableViewCellSelectionStyleNone;
    cell.backgroundColor = [UIColor whiteColor];
    
    [cell makeViews];
    
    return cell;
}

- (void)makeViews {
    
    CGFloat width = (SCREEN_WIDTH-50);
    
    [self.contentView addSubview:self.textField];
    [self.textField mas_makeConstraints:^(MASConstraintMaker *make) {
        make.left.mas_equalTo(25);
        make.top.mas_equalTo(10);
        make.height.mas_equalTo(28);
        make.width.mas_equalTo(width);
    }];
    
}

- (void)setPlaceHolder:(NSString *)placeHolder {
    self.textField.placeholder = placeHolder;
}

- (UITextField *)textField {
    if (!_textField) {
        _textField = [[UITextField alloc] init];
        _textField.borderStyle = UITextBorderStyleNone;
        _textField.textColor = UIColorFromRGB(0x333333);
        _textField.font = [UIFont systemFontOfSize:14];
        _textField.text = @"";
    }
    
    return _textField;
}

@end
